﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using Qplus.protocol;
using Qplus.enums;
using Qplus.Infrastructure;
using Qplus.beans;

namespace Qplus.UI
{
    public class ProtocolCommand
    {
        private static ProtocolCommand instance;

        public static ProtocolCommand Instance { get { if (null == instance)instance = new ProtocolCommand(); return instance; } }

        #region 用户登录、退出
        // 验证登陆
        public void pcmd_C2L_REQ_LOGIN()
        {

        }
        // 验证登陆应答
        public void pcmd_L2C_RESP_LOGIN()
        {

        }
        // 登陆用户服务器
        public void pcmd_C2U_REQ_LOGIN ()
        {

        }
        // 登陆用户服务器应答
        public void pcmd_U2C_RESP_LOGIN ()
        {

        }
        // 退出登录
        public void pcmd_C2U_REQ_LOGOUT ()
        {

        }
        // 退出登陆应答
        public void pcmd_U2C_RESP_LOGOUT ()
        {

        }
        // 心跳包
        public void pcmd_C2U_NOTIFY_CLIENT_ONLINE ()
        {

        }
#endregion

        #region 系统消息
        public void pcmd_U2C_NOTIFY_SYSTEM_MSG()
        {

        }
        public void pcmd_U2C_SYN_FORCE_LOGOUT()
        {

        }
        public void pcmd_C2U_REQ_SHORT_MSG()
        {

        }
        public void pcmd_U2C_RESP_SHORT_MSG()
        {

        }
        public void pcmd_U2C_NOTIFY_SHORT_MSG()
        {

        }
        #endregion

        #region 客服聊天
        // 开始会话请求
        public void pcmd_C2U_REQ_CUSTOMER_SERVICE()
        {

        }
        // 连接客服应答
        public void pcmd_U2C_RESP_CUSTOMER_SERVICE ()
        {

        }
        public void pcmd_C2U_REQ_SESSION_BEGIN ()
        {

        }
        public void pcmd_U2C_RESP_SESSION_BEGIN ()
        {

        }
        public void pcmd_U2C_NOTIFY_SESSION_BEGIN ()
        {

        }
        public void pcmd_C2U_REQ_SESSION_END ()
        {

        }
        public void pcmd_U2C_RESP_SESSION_END ()
        {

        }
        public void pcmd_U2C_NOTIFY_SESSION_END ()
        {

        }
        public void pcmd_C2U_REQ_CHAT_SENDMSG ()
        {

        }
        public void pcmd_U2C_RESP_CHAT_SENDMSG ()
        {

        }
        public void pcmd_U2C_NOTIFY_CHAT_RECVMSG ()
        {

        }
        public void pcmd_C2U_REQ_CHAT_VOICEBEGIN ()
        {

        }
        public void pcmd_U2C_RESP_CHAT_VOICEBEGIN ()
        {

        }
        public void pcmd_U2C_NOTIFY_CHAT_VOICEBEGIN ()
        {

        }
        public void pcmd_C2U_REQ_CHAT_VOICEDATA ()
        {

        }
        public void pcmd_U2C_NOTIFY_CHAT_VOICEDATA ()
        {

        }
        public void pcmd_C2U_REQ_CHAT_VOICEEND ()
        {

        }
        public void pcmd_U2C_RESP_CHAT_VOICEEND ()
        {

        }
        public void pcmd_U2C_NOTIFY_CHAT_VOICEEND ()
        {

        }
        #endregion

        #region 聊天室
        public void pcmd_C2U_REQ_ROOM_PEOPLE_COUNT(long roomID)
        {
            MessageID MID = MessageID.getInstance();
            MID.setBody(MMessageID.C2U_REQ_ROOM_PEOPLE_COUNT);
            C2U_REQ_ROOM_PEOPLE_COUNT p = (C2U_REQ_ROOM_PEOPLE_COUNT)MID.getBody();
            p.getRoomPeopleCount(roomID);
            ConnectionManager.getInstance().send(p);
        }
	    public void pcmd_U2C_RESP_ROOM_PEOPLE_COUNT ()
        {

        }
        public void pcmd_C2U_REQ_ENTER_ROOM(long roomID)
        {
        }
	    public void pcmd_U2C_RESP_ENTER_ROOM ()
        {

        }
        public void pcmd_C2U_REQ_LEAVE_ROOM(long RoomID)
        {
        }
	    public void pcmd_U2C_RESP_LEAVE_ROOM ()
        {

        }
	    public void pcmd_C2U_REQ_ROOM_SENDMSG (E_MESSAGE_TYPE msgtype,byte[] msg)
        {
            MessageID MID = MessageID.getInstance();
            MID.setBody(MMessageID.C2U_REQ_ROOM_SENDMSG);
            C2U_REQ_ROOM_SENDMSG p = (C2U_REQ_ROOM_SENDMSG)MID.getBody();
            p.sendMessage(Room.CurrentRoomInstance.RoomID, (int)msgtype, msg, msg.Length);
            ConnectionManager.getInstance().send(p);

        }
	    public void pcmd_U2C_RESP_ROOM_SENDMSG ()
        {

        }
	    public void pcmd_U2C_NOTIFY_ROOM_RECVTMSG ()
        {

        }
        public void pcmd_C2U_REQ_ROOM_VOICEBEGIN(long roomID)
        {
            MessageID MID = MessageID.getInstance();
            MID.setBody(MMessageID.C2U_REQ_ROOM_VOICEBEGIN);
            C2U_REQ_ROOM_VOICEBEGIN p = (C2U_REQ_ROOM_VOICEBEGIN)MID.getBody();
            p.sendVoiceRequset(roomID);
            ConnectionManager.getInstance().send(p);
        }
	    public void pcmd_U2C_RESP_ROOM_VOICEBEGIN ()
        {

        }
	    public void pcmd_U2C_NOTIFY_ROOM_VOICEBEGIN ()
        {

        }
	    public void pcmd_C2U_REQ_ROOM_SENDVOICE ()
        {

        }
	    public void pcmd_U2C_NOTIFY_ROOM_RECVVOICE ()
        {

        }
	    public void pcmd_C2U_REQ_ROOM_VOICEEND (long roomID)
        {
            MessageID MID = MessageID.getInstance();
            MID.setBody(MMessageID.C2U_REQ_ROOM_VOICEEND);
            C2U_REQ_ROOM_VOICEEND p = (C2U_REQ_ROOM_VOICEEND)MID.getBody();
            p.stopVoice(roomID);
            ConnectionManager.getInstance().send(p);
        }
	    public void pcmd_U2C_RESP_ROOM_VOICEEND ()
        {

        }
	    public void pcmd_U2C_NOTIFY_ROOM_VOICEEND ()
        {

        }
	    public void pcmd_C2U_REQ_USER_LIST (long roomID)
        {
            MessageID MID = MessageID.getInstance();
            MID.setBody(MMessageID.C2U_REQ_USER_LIST);
            C2U_REQ_USER_LIST p = (C2U_REQ_USER_LIST)MID.getBody();
            p.getRoomUserList(roomID);
            ConnectionManager.getInstance().send(p);
        }
	    public void pcmd_U2C_RESP_USER_LIST ()
        {

        }
	    public void pcmd_U2C_NOTIFY_ROOM_MSGLOG_RECORD ()//(保留未用)
        {

        }
        #endregion

        #region 客服权限
        public void pcmd_C2U_REQ_ROOM_BANNED()
        {

        }
	    public void pcmd_U2C_NOTIFY_ROOM_BANNED ()
        {

        }
        public void pcmd_U2C_RESP_ROOM_BANNED()
        {

        }
        #endregion

    }
}
